package com.blog.properties;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;
import org.springframework.stereotype.Component;

//@ConfigurationProperties(prefix = "cly.jwt")
//@Data
//@Component//加入ioc容器
public class JwtProperties {

    //生成JWT令牌的必要属性
    public static final String secretKey = "cly"; // 设置jwt签名加密时使用的密钥
    public static final long time = 7200000; // 设置jwt过期的时间
    public static final String tokenName = "token"; // 设置前端传递过来的令牌的名称
    public static final String ROLE_USER = "USER";
    public static final String ROLE_ADMIN = "ADMIN";
}
